//连接数据库

const mongoose = require('../db/connection')

const userSchema = new mongoose.Schema({
    username:{
        type:String,
        require:true
    },
    password:{
        type:String,
        require:true 
    },
    email:{
        type:String,
        require:true 
    },
    avatar:String
})

const userModel = mongoose.model('users',userSchema,'users')

//导出
module.exports = userModel